package com.hoh.phonelocation.service;

import com.hoh.phonelocation.model.entity.PhoneInfo;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hoh.phonelocation.model.response.GetPhoneLocationResponse;
import com.hoh.phonelocation.model.vo.PhoneLocationVO;
import org.springframework.retry.annotation.Backoff;
import org.springframework.retry.annotation.Retryable;

import java.net.SocketTimeoutException;
import java.net.UnknownHostException;
import java.sql.SQLException;

/**
* @author hongzizhou
* @description 针对表【phone_info】的数据库操作Service
* @createDate 2025-03-02 14:46:00
*/
public interface PhoneInfoService extends IService<PhoneInfo> {

    /**
     * 获取电话号位置信息
     * @param phone
     * @return
     */
    public PhoneLocationVO getPhoneLocation(String phone);

    /**
     * 通过接口获取电话号归属地
     * @param phone
     * @return
     */
    public GetPhoneLocationResponse.Location getPhoneLocationByInterface(String phone);

    /**
     * 验证电话号码
     * @param phone
     * @return
     */
    public boolean validPhoneNumber(String phone);
}
